package com.xf.service.impl;

import com.xf.entity.SysUser;
import com.xf.mapper.PersonDao;
import com.xf.service.PersonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @auther : fengh
 * @date : 2024/2/4 16:16
 */
@Service
public class PersonServiceImpl implements PersonService {

    @Autowired
    private PersonDao dao;

    public List<SysUser> findAll() {
        return dao.findAll();
    }

    public SysUser findById(Long id) {
        return dao.findById(id);
    }

    public int insert(SysUser sysUser) {
        int insert = dao.insert(sysUser);
        return insert;
    }

    public void update(SysUser sysUser) {
        dao.update(sysUser);
    }

    public void delete(Long id) {
        dao.delete(id);
    }
}
